﻿<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8" />
    <title>parent属性的应用</title>
</head>
<script>
    function openWin() {
        window.open('', '', 'width=200,height=100');

        alert(window.parent.location);
    }
</script>
<body>
    <input type="button" value="打开窗口" onclick="openWin()" />
</body>
</html>